[SUBROUTINE]
version = 1.14
icon = hexagon.png
name = _("Polygon")
type = polygon
help = _("<b>Create a Polygon with n edges</b>")
order = act pv h1 cx cy h10 n r rot h3 opt dir

[PARAM_ACT]
name = _("Active")
icon = enable.png
type = bool
value = 1

[PARAM_PV]
name = _("Show design")
icon = glasses.png
type = bool
value = 1

[PARAM_H1]
name = _("Coords")
type = sub-header

[PARAM_H10]
name = _("Size, rotation")
type = sub-header

[PARAM_CX]
name = _("cX")
type = float
icon = center.png
tool_tip = _("Polygon center X")
header = h1
value = 0
metric_value = 0.0

[PARAM_CY]
name = _("cY")
type = float
icon = center.png
tool_tip = _("Polygon center Y")
value = 0
metric_value = 0.0
header = h1

[PARAM_N]
name = _("Edges count")
type = int
minimum_value = 3
maximum_value = 360
icon = num.png
tool_tip = _("Number of edges")
value = 6
header = h10

[PARAM_R]
name = _("Radius")
type = float
minimum_value = 0.0
icon = hexagon-rad.png
tool_tip = _("Radius")
value = 1
header = h10
metric_value = 25
not_allowed = 0

[PARAM_ROT]
name = _("Rotation")
type = float
digits = 2
icon = angle.png
tool_tip = _("Start angle")
value = 0
header = h10
suffix = &#176;

[PARAM_H3]
name = _("Cutting")
type = sub-header

[PARAM_OPT]
name = _("Option")
type = combo
options = _("Inside=0:On the line=2:Outside=3")
icon = g4x.png
tool_tip = _("Select tool path")
value = 0
header = h3

[PARAM_DIR]
name = _("Direction")
type = combo
options = _("Clockwise=2:Counter-Clockwise=3")
icon = cw-ccw.png
tool_tip = _("Direction of path")
value = 3
header = h3

[DEFINITIONS]
content =
;	<eval>self.include_once(file name here)</eval>

[CALL]
content =
	(begin #sub_name)
	(polygon of #param_n edges author : Fernand Veilleux)
	o<#self_id_active> if [#param_act] (if active)
		o<polygon> CALL [#param_cx] [#param_cy] [#param_n] [#param_r] [#param_rot] [#param_opt] [#param_dir] [#<pl_cut_start>] [#<surface>] [#<bottom>] [#param_pv]
	o<#self_id_active> endif
